package chapter04.Example15_17;
class Amimal{
    public void  shout(){
        System.out.println("喵喵");
    }
}
class Dog2 extends Amimal{
    public void  shout(){
        System.out.println("汪汪");
    }
    public void eat(){
        System.out.println("吃屎");
    }
}
public class Example16 {
    public static void main(String[] args) {
        Amimal an = new Dog2();
        Dog dog = new Dog();
        dog.shout();
        dog.eat();
    }
}
